package com.gridmobi.xrtb.domain.dsp;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

public class JOfferActiveDayExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    private Integer limit;

    private Integer offset;

    public JOfferActiveDayExample() {
        oredCriteria = new ArrayList<Criteria>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    public void setLimit(Integer limit) {
        this.limit = limit;
    }

    public Integer getLimit() {
        return limit;
    }

    public void setOffset(Integer offset) {
        this.offset = offset;
    }

    public Integer getOffset() {
        return offset;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<Criterion>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andIdIsNull() {
            addCriterion("id is null");
            return (Criteria) this;
        }

        public Criteria andIdIsNotNull() {
            addCriterion("id is not null");
            return (Criteria) this;
        }

        public Criteria andIdEqualTo(Integer value) {
            addCriterion("id =", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotEqualTo(Integer value) {
            addCriterion("id <>", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThan(Integer value) {
            addCriterion("id >", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdGreaterThanOrEqualTo(Integer value) {
            addCriterion("id >=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThan(Integer value) {
            addCriterion("id <", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdLessThanOrEqualTo(Integer value) {
            addCriterion("id <=", value, "id");
            return (Criteria) this;
        }

        public Criteria andIdIn(List<Integer> values) {
            addCriterion("id in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotIn(List<Integer> values) {
            addCriterion("id not in", values, "id");
            return (Criteria) this;
        }

        public Criteria andIdBetween(Integer value1, Integer value2) {
            addCriterion("id between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andIdNotBetween(Integer value1, Integer value2) {
            addCriterion("id not between", value1, value2, "id");
            return (Criteria) this;
        }

        public Criteria andAffidIsNull() {
            addCriterion("affid is null");
            return (Criteria) this;
        }

        public Criteria andAffidIsNotNull() {
            addCriterion("affid is not null");
            return (Criteria) this;
        }

        public Criteria andAffidEqualTo(Integer value) {
            addCriterion("affid =", value, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidNotEqualTo(Integer value) {
            addCriterion("affid <>", value, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidGreaterThan(Integer value) {
            addCriterion("affid >", value, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidGreaterThanOrEqualTo(Integer value) {
            addCriterion("affid >=", value, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidLessThan(Integer value) {
            addCriterion("affid <", value, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidLessThanOrEqualTo(Integer value) {
            addCriterion("affid <=", value, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidIn(List<Integer> values) {
            addCriterion("affid in", values, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidNotIn(List<Integer> values) {
            addCriterion("affid not in", values, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidBetween(Integer value1, Integer value2) {
            addCriterion("affid between", value1, value2, "affid");
            return (Criteria) this;
        }

        public Criteria andAffidNotBetween(Integer value1, Integer value2) {
            addCriterion("affid not between", value1, value2, "affid");
            return (Criteria) this;
        }

        public Criteria andAffnameIsNull() {
            addCriterion("affname is null");
            return (Criteria) this;
        }

        public Criteria andAffnameIsNotNull() {
            addCriterion("affname is not null");
            return (Criteria) this;
        }

        public Criteria andAffnameEqualTo(String value) {
            addCriterion("affname =", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameNotEqualTo(String value) {
            addCriterion("affname <>", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameGreaterThan(String value) {
            addCriterion("affname >", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameGreaterThanOrEqualTo(String value) {
            addCriterion("affname >=", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameLessThan(String value) {
            addCriterion("affname <", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameLessThanOrEqualTo(String value) {
            addCriterion("affname <=", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameLike(String value) {
            addCriterion("affname like", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameNotLike(String value) {
            addCriterion("affname not like", value, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameIn(List<String> values) {
            addCriterion("affname in", values, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameNotIn(List<String> values) {
            addCriterion("affname not in", values, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameBetween(String value1, String value2) {
            addCriterion("affname between", value1, value2, "affname");
            return (Criteria) this;
        }

        public Criteria andAffnameNotBetween(String value1, String value2) {
            addCriterion("affname not between", value1, value2, "affname");
            return (Criteria) this;
        }

        public Criteria andTotaloffersIsNull() {
            addCriterion("totaloffers is null");
            return (Criteria) this;
        }

        public Criteria andTotaloffersIsNotNull() {
            addCriterion("totaloffers is not null");
            return (Criteria) this;
        }

        public Criteria andTotaloffersEqualTo(Integer value) {
            addCriterion("totaloffers =", value, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersNotEqualTo(Integer value) {
            addCriterion("totaloffers <>", value, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersGreaterThan(Integer value) {
            addCriterion("totaloffers >", value, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersGreaterThanOrEqualTo(Integer value) {
            addCriterion("totaloffers >=", value, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersLessThan(Integer value) {
            addCriterion("totaloffers <", value, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersLessThanOrEqualTo(Integer value) {
            addCriterion("totaloffers <=", value, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersIn(List<Integer> values) {
            addCriterion("totaloffers in", values, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersNotIn(List<Integer> values) {
            addCriterion("totaloffers not in", values, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersBetween(Integer value1, Integer value2) {
            addCriterion("totaloffers between", value1, value2, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andTotaloffersNotBetween(Integer value1, Integer value2) {
            addCriterion("totaloffers not between", value1, value2, "totaloffers");
            return (Criteria) this;
        }

        public Criteria andValidoffercountIsNull() {
            addCriterion("validoffercount is null");
            return (Criteria) this;
        }

        public Criteria andValidoffercountIsNotNull() {
            addCriterion("validoffercount is not null");
            return (Criteria) this;
        }

        public Criteria andValidoffercountEqualTo(Integer value) {
            addCriterion("validoffercount =", value, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountNotEqualTo(Integer value) {
            addCriterion("validoffercount <>", value, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountGreaterThan(Integer value) {
            addCriterion("validoffercount >", value, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountGreaterThanOrEqualTo(Integer value) {
            addCriterion("validoffercount >=", value, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountLessThan(Integer value) {
            addCriterion("validoffercount <", value, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountLessThanOrEqualTo(Integer value) {
            addCriterion("validoffercount <=", value, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountIn(List<Integer> values) {
            addCriterion("validoffercount in", values, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountNotIn(List<Integer> values) {
            addCriterion("validoffercount not in", values, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountBetween(Integer value1, Integer value2) {
            addCriterion("validoffercount between", value1, value2, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andValidoffercountNotBetween(Integer value1, Integer value2) {
            addCriterion("validoffercount not between", value1, value2, "validoffercount");
            return (Criteria) this;
        }

        public Criteria andActiveofferIsNull() {
            addCriterion("activeoffer is null");
            return (Criteria) this;
        }

        public Criteria andActiveofferIsNotNull() {
            addCriterion("activeoffer is not null");
            return (Criteria) this;
        }

        public Criteria andActiveofferEqualTo(Integer value) {
            addCriterion("activeoffer =", value, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferNotEqualTo(Integer value) {
            addCriterion("activeoffer <>", value, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferGreaterThan(Integer value) {
            addCriterion("activeoffer >", value, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferGreaterThanOrEqualTo(Integer value) {
            addCriterion("activeoffer >=", value, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferLessThan(Integer value) {
            addCriterion("activeoffer <", value, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferLessThanOrEqualTo(Integer value) {
            addCriterion("activeoffer <=", value, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferIn(List<Integer> values) {
            addCriterion("activeoffer in", values, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferNotIn(List<Integer> values) {
            addCriterion("activeoffer not in", values, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferBetween(Integer value1, Integer value2) {
            addCriterion("activeoffer between", value1, value2, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andActiveofferNotBetween(Integer value1, Integer value2) {
            addCriterion("activeoffer not between", value1, value2, "activeoffer");
            return (Criteria) this;
        }

        public Criteria andDaysIsNull() {
            addCriterion("days is null");
            return (Criteria) this;
        }

        public Criteria andDaysIsNotNull() {
            addCriterion("days is not null");
            return (Criteria) this;
        }

        public Criteria andDaysEqualTo(String value) {
            addCriterion("days =", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotEqualTo(String value) {
            addCriterion("days <>", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysGreaterThan(String value) {
            addCriterion("days >", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysGreaterThanOrEqualTo(String value) {
            addCriterion("days >=", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysLessThan(String value) {
            addCriterion("days <", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysLessThanOrEqualTo(String value) {
            addCriterion("days <=", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysLike(String value) {
            addCriterion("days like", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotLike(String value) {
            addCriterion("days not like", value, "days");
            return (Criteria) this;
        }

        public Criteria andDaysIn(List<String> values) {
            addCriterion("days in", values, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotIn(List<String> values) {
            addCriterion("days not in", values, "days");
            return (Criteria) this;
        }

        public Criteria andDaysBetween(String value1, String value2) {
            addCriterion("days between", value1, value2, "days");
            return (Criteria) this;
        }

        public Criteria andDaysNotBetween(String value1, String value2) {
            addCriterion("days not between", value1, value2, "days");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeIsNull() {
            addCriterion("updatetime is null");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeIsNotNull() {
            addCriterion("updatetime is not null");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeEqualTo(Date value) {
            addCriterion("updatetime =", value, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeNotEqualTo(Date value) {
            addCriterion("updatetime <>", value, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeGreaterThan(Date value) {
            addCriterion("updatetime >", value, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeGreaterThanOrEqualTo(Date value) {
            addCriterion("updatetime >=", value, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeLessThan(Date value) {
            addCriterion("updatetime <", value, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeLessThanOrEqualTo(Date value) {
            addCriterion("updatetime <=", value, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeIn(List<Date> values) {
            addCriterion("updatetime in", values, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeNotIn(List<Date> values) {
            addCriterion("updatetime not in", values, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeBetween(Date value1, Date value2) {
            addCriterion("updatetime between", value1, value2, "updatetime");
            return (Criteria) this;
        }

        public Criteria andUpdatetimeNotBetween(Date value1, Date value2) {
            addCriterion("updatetime not between", value1, value2, "updatetime");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {

        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}